package com.xuz.decorator.example02;

/**
 * @user 65453
 * @date 2024/10/14 21:56
 */
public class TestDecorator {
    public static void main(String[] args) {

        String info = "name:tom,age:15";
        DataLoaderDecorator decorator = new EncryptionDataDecorator(new BaseFileDataLoader("demo.txt"));
        decorator.write(info);

        String data = decorator.read();
        System.out.println(data);
    }
}
